package com.exam.hibuy.service.impl;

import com.exam.hibuy.mapper.ResourcesMapper;
import com.exam.hibuy.model.Resources;
import com.exam.hibuy.service.ResourcesService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;
import java.util.Map;

/**
 * Created by admin on 2017/12/1.
 */
@Service("resourcesService")
@Transactional(rollbackFor = Exception.class)
public class ResourcesServiceImpl implements ResourcesService {

    @Autowired
    private ResourcesMapper resourcesMapper;

    @Override
    public List<Resources> queryAll() {
        return resourcesMapper.queryAll();
    }

    @Override
    public List<Resources> loadUserResources(Map<String, Object> map) {

        return resourcesMapper.loadUserResources(map);
    }
}
